{% load static %}
<!DOCTYPE html>
<html lang="zh-CN">
<head>
    <meta charset="utf-8">
    <meta http-equiv="X-UA-Compatible" content="IE=edge">
    <meta name="viewport" content="width=device-width, initial-scale=1">
    <title>厚浦博客</title>
    <link href="{% static 'bootstrap/css/bootstrap.min.css' %}" rel="stylesheet">
    <link href="{% static 'css/cl-css.css' %}" rel="stylesheet">
    <link href="{% static 'font-awesome/css/font-awesome.min.css' %}" rel="stylesheet">
    <link rel="stylesheet" href="{% static 'highlight/styles/railscasts.css' %}">
    <script src="../static/ckeditor/ckeditor/ckeditor.js" type="text/javascript" charset="utf-8"></script>
</head>
<body>
<div id="app">
    <div class="cl-header container-fluid">
        <div class="header-content container">
            <nav class="navbar navbar-expand-lg navbar-light">
                <a class="navbar-brand" href="/">
                    <img src="{% static 'img/logo.jpg' %}" width="144" height="72" alt="">
                </a>
                <button class="navbar-toggler" type="button" data-toggle="collapse" data-target="#navbarNav"
                        aria-controls="navbarNav" aria-expanded="false" aria-label="Toggle navigation">
                    <span class="navbar-toggler-icon"></span>
                </button>
                <div class="collapse navbar-collapse justify-content-end" id="navbarNav">
                    <ul class="navbar-nav">
                        <li class="nav-item active">
{#                            <a class="nav-link" href="calmlog-index.html">首页 <span class="sr-only">(current)</span></a>#}
                        </li>
                        <li class="nav-item">
{#                            <a class="nav-link" href="#">教程</a>#}
                        </li>
                        <li class="nav-item">
{#                            <a class="nav-link" href="#">模板</a>#}
                        </li>
                        <li class="nav-item">
{#                            <a class="nav-link" href="#">日记</a>#}
                        </li>
                        <li class="nav-item">
{#                            <a class="nav-link" href="#">关于</a>#}
                        </li>
                    </ul>
                </div>
            </nav>
        </div>
    </div>
    <div class="cl-cantainer container pt-5">
        <form class="col-md-8 offset-md-2" method="post" enctype="multipart/form-data">
            {% csrf_token %}
            <div class="form-group">
                <label for="avatar">上传图片</label>
                <input type="file" class="form-control-file" name="avatar" id="avatar">
            </div>
            <div class="form-group">
                <lable for="">文章标题</lable>
                <input type="text" class="form-control" placeholder="文章标题" name="title">
            </div>
            <div class="form-group">
                <lable for="column">栏目</lable>
                <select class="form-control col-12" id="category" name="category">
                        {% for category in categories %}
                            <option value="{{ category.id }}">{{ category.title }}</option>
                        {% endfor %}
                </select>
            </div>
            <div class="form-group">
                <lable for="">标签</lable>
                <input type="text" class="form-control" placeholder="文章标签" name="tags">
            </div>
            <div class="form-group">
                <lable for="">文章摘要</lable>
                <input type="text" class="form-control" placeholder="文章摘要" name="sumary">
            </div>
            <div class="form-group">
                <lable for="">文章正文</lable>
                <textarea name="content" id="editor1" rows="10" cols="80">
                  我是付博文编辑器里面的内容
                 </textarea>
                <script>
                    // Replace the <textarea id="editor1"> with a CKEditor 4
                    // instance, using default configuration.
                    CKEDITOR.replace('editor1');
                </script>
            </div>
            <div class="form-group">
                <button type="submit" class="btn btn-primary btn-block">提交</button>
            </div>
            <div class="form-group">
                <td class="text-danger">{{ msg }}</td>
            </div>
        </form>
    </div>
    <div class="container-fluid cl-footer">
        <div class="container">
            <p class="cl-copyright">本设计由简.工作室荣誉出品</p>
            <p class="cl-copyright">copyright @ 2017~2018 简.工作室（www.jeanstudio.cn）</p>
        </div>
    </div>
</div>
<script src="{% static 'jquery/jquery.min.js' %}"></script>
<script src="{% static 'bootstrap/js/bootstrap.min.js' %}"></script>
<script src="{% static 'highlight/highlight.pack.js' %}"></script>
{#<script src="{% static 'vue/vue-2.5.16.js' %}"></script>#}
<script src="{% static 'js/host.js' %}"></script>
<script src="{% static 'js/register.js' %}"></script>
<script src="{% static 'vue/axios-0.18.0.min.js' %}"></script>
<script>hljs.initHighlightingOnLoad();</script>
</body>
</html>
